<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script type="text/javascript" src="jquery.min.js"></script>
		<style type="text/css">
			div {
				width: 100px;
				height: 100px;
				background-color: pink;
			}
		</style>
	</head>
	<body>
		<script type="text/javascript">
			//1.等待页面DOM加载完毕后在执行js代码
			// $(document).ready(function() {
			// 	$('div').hide();
			// });
			//2.等待页面DOM加载完毕后在执行js代码-简写
			$(function() {
				$('div').hide();
			});
		</script>
		<div id="">

		</div>
	</body>
</html>
